package com.steadyoung.modelapp.fragment;

import android.os.Bundle;
import android.support.v7.widget.GridLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.steadyoung.modelapp.R;
import com.steadyoung.modelapp.adapter.LoadingAdapter;
import com.steadyoung.modelapp.base.BaseFragment;

import java.util.Arrays;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.Unbinder;

/**
 * Created by Administrator on 2017/12/4.
 * Email : steadyoung@foxmail.com
 * Auth  : wayne
 * Desc  : TODO
 */

public class LoadingFragment extends BaseFragment {
    @BindView(R.id.recycler_view)
    RecyclerView recyclerView;

    LoadingAdapter loadingAdapter;

    @Override
    protected int getLayoutResId() {
        return R.layout.fm_loading;
    }

    @Override
    protected void initData() {
        recyclerView.setLayoutManager(new GridLayoutManager(mContext,4));
        loadingAdapter = new LoadingAdapter(Arrays.asList(INDICATORS));
        recyclerView.setAdapter(loadingAdapter);
    }

    @Override
    protected void initEvent() {

    }

    /**
     *
     */
    private static final String[] INDICATORS = new String[]{
            "BallPulseIndicator",
            "BallGridPulseIndicator",
            "BallClipRotateIndicator",
            "BallClipRotatePulseIndicator",
            "SquareSpinIndicator",
            "BallClipRotateMultipleIndicator",
            "BallPulseRiseIndicator",
            "BallRotateIndicator",
            "CubeTransitionIndicator",
            "BallZigZagIndicator",
            "BallZigZagDeflectIndicator",
            "BallTrianglePathIndicator",
            "BallScaleIndicator",
            "LineScaleIndicator",
            "LineScalePartyIndicator",
            "BallScaleMultipleIndicator",
            "BallPulseSyncIndicator",
            "BallBeatIndicator",
            "LineScalePulseOutIndicator",
            "LineScalePulseOutRapidIndicator",
            "BallScaleRippleIndicator",
            "BallScaleRippleMultipleIndicator",
            "BallSpinFadeLoaderIndicator",
            "LineSpinFadeLoaderIndicator",
            "TriangleSkewSpinIndicator",
            "PacmanIndicator",
            "BallGridBeatIndicator",
            "SemiCircleSpinIndicator",
            "com.steadyoung.modelapp.widget.loading.MyCustomIndicator"
    };
}
